﻿#include "mainwindow.h"
#include <QDockWidget>

MainWindow::MainWindow(QWidget *parent)
    : QMainWindow(parent)
{
    init();
    addCodeEditor();

}

MainWindow::~MainWindow()
{
}

void MainWindow::init()
{
    this->setWindowTitle(tr("Notepad"));
    this->setWindowState(Qt::WindowMaximized);
    this->setMinimumSize(800, 600);
}


void MainWindow::addCodeEditor()
{
    codeEditor = new CodeEditor();
    codeEditor->setTabStopWidth(40);
    codeEditor->setStyleSheet("color:#333; font-size:18px; line-height:50px; font-family:\"Courier New\", Courier, monospace, \"Times New Roman\", Times, serif, Arial, Helvetica, sans-serif, Verdana");
    this->setCentralWidget(codeEditor);
}


